#!/bin/bash

#
# Wrapper around jenkins_generic_job that will allow output
# from that script to always be printed to the screen and
# recoverable if Jenkins is forced to kill the job. This is the
# script that should be used from Jenkins.
#

SCRIPT_DIR=$( cd "$( dirname "$0" )" && pwd )
DATE_STAMP=$(date "+%Y-%m-%d_%H%M%S")
export JENKINS_START_TIME=$(date "+%s")

umask 002

$SCRIPT_DIR/jenkins_generic_job --submit-to-cdash --update-success "$@" >& JENKINS_$DATE_STAMP
